//
//  SHEHomeListCell.m
//  SHEPuzzleFigure
//
//  Created by SW mini on 2019/11/25.
//  Copyright © 2019 Figure. All rights reserved.
//

#import "SHEHomeListCell.h"

@interface SHEHomeListCell ()

@property (weak, nonatomic) IBOutlet UIImageView *imgView;
@property (weak, nonatomic) IBOutlet UILabel *textLabel;
@property (weak, nonatomic) IBOutlet UIView *lockView;
@property (weak, nonatomic) IBOutlet UIView *bgView;


@end



@implementation SHEHomeListCell

- (void)awakeFromNib {
    [super awakeFromNib];

    [_textLabel addShadow];
    
    self.layer.shadowOffset = CGSizeMake(1, 2);
    self.layer.shadowColor = [UIColor blackColor].CGColor;
    self.layer.shadowOpacity = 0.7;
    self.layer.shadowRadius = 2;
}

- (void)setHomeDict:(NSDictionary *)homeDict{
    
    self.bgView.layer.cornerRadius = 6.0;
    self.bgView.layer.masksToBounds = YES;
    self.lockView.hidden = YES;
    
    NSString *url = [NSString stringWithFormat:@"%@%@",API_HOST,homeDict[@"image_url"]];
    [self.imgView yy_setImageWithURL:[NSURL URLWithString:url] placeholder:nil];
    
    self.textLabel.text = homeDict[@"title"];
    self.textLabel.font = [UIFont fontWithName:@"FZY4K--GBK1-0" size:14.0];
    
}


@end
